package io.renren.wechat.authen.dao;

import org.apache.ibatis.annotations.Insert;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Select;
import org.springframework.stereotype.Repository;

/**
 * Created by Administrator on 2018/3/19 0019.
 */
@Mapper
@Repository
public interface LoginDao {
    @Select("select user_id from wechat_login where open_id=#{openId}")
    String findUserIdByOpenId(String openId);
    @Insert("Insert into wechat_login(username,openId) values(#{username},#{openId})")
    void insertWecharData(String username,String openId);
}
